gtkgesturesingle: Fallback to GtkGesture handling on GDK_TOUCHPAD_SWIPE
authorCarlos Garnacho <carlosg@gnome.org>
Thu, 2 Mar 2017 17:14:00 +0000 (18:14 +0100)
committerCarlos Garnacho <carlosg@gnome.org>
Thu, 2 Mar 2017 17:25:04 +0000 (18:25 +0100)
There are GtkGestureSingle subclasses that can be made to handle multiple
fingers (GtkGestureSingle is a subclass of GtkGesture, and not the
opposite, after all). And GtkGestureSwipe already tries to handle
GDK_TOUCHPAD_SWIPE events, except this event handler silently ignores
those.

Falling back to the GtkGesture generic handler which already
handles touchpad gesture events fixes this.

gtk/gtkgesturesingle.c

index 5aa0978050d5b483cc4b0f8205477bb24f144709..7e3a5e895c95d033a3e6e3fb2fb6491dfa51f8fa 100644 (file)
@@ -193,6 +193,7 @@ gtk_gesture_single_handle_event (GtkEventController *controller,
       break;
     case GDK_TOUCH_CANCEL:
     case GDK_GRAB_BROKEN:
+    case GDK_TOUCHPAD_SWIPE:
       return GTK_EVENT_CONTROLLER_CLASS (gtk_gesture_single_parent_class)->handle_event (controller,
                                                                                          event);
       break;